<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <script type="text/javascript" src="../assets/js/vue.js"></script>
    <title>propsData Option 全局扩展的数据传递</title>
</head>

<body>
    <h1>propsData Option 全局扩展的数据传递</h1>
    <hr>
    <div id="app">
        <headerA></headerA>
    </div>
    <script type="text/javascript">
        var header_a = Vue.extend({
            template:`<p style="color:red">{{message}} - {{a}}</p>`,
            data:function () {
                return{
                    message:"我是头部组件"
                }
              },
             props:['a'] 
        });
        new header_a({propsData:{a:12}}).$mount('headerA');
    </script>
</body>

</html>